.\" $Id: PAPI_get_shared_lib_info.3,v 1.7 2004/09/27 19:41:06 london Exp $
.TH PAPI_get_shared_lib_info 3 "September, 2004" "PAPI Programmer's Reference" "PAPI"

.SH NAME
PAPI_get_shared_lib_info \- get address info about the shared libraries used by the process 

.SH SYNOPSIS
.B C Interface
.nf
.B #include <papi.h>
.BI "const PAPI_shlib_info_t *PAPI_get_shared_lib_info(void);"
.fi

.SH DESCRIPTION
In C, this function returns a pointer to a structure containing information
about the shared library used by the program. There is no Fortran equivalent call.

.SH NOTE
This data will be incorporated into the
.B PAPI_get_executable_info 
call in the future. 
.PAPI_get_shared_lib_info 
will be deprecated and should be used with caution.


.SH RETURN VALUES
On success, the function returns a non-NULL pointer.
 On error, NULL is returned.

.SH DATA STRUCTURE
.LP
.nf
.if t .ft CW
   typedef struct _papi_address_map {
      char name[PAPI_MAX_STR_LEN];
      caddr_t text_start;       /* Start address of program text segment */
      caddr_t text_end;         /* End address of program text segment */
      caddr_t data_start;       /* Start address of program data segment */
      caddr_t data_end;         /* End address of program data segment */
      caddr_t bss_start;        /* Start address of program bss segment */
      caddr_t bss_end;          /* End address of program bss segment */
   } PAPI_address_map_t;

   typedef struct _papi_shared_lib_info {
      PAPI_address_map_t *map;
      int count;
   } PAPI_shlib_info_t;
.if t .ft P
.fi

.SH BUGS
If called before 
.B PAPI_library_init()
the behavior of the routine is undefined.

.SH SEE ALSO
.BR PAPI_library_init "(3), "
.BR PAPI_get_opt "(3), " 
.BR PAPI_get_dmem_info "(3), "
.BR PAPI_get_executable_info "(3), "
.BR PAPI_get_hardware_info "(3)"
